import request from '/@/utils/request';
export function AppAttrApi() {
	return {
		create: (data: object) => {
			return request({
				url: 'management/appattr/create',
				method: 'post',
				data,
			});
		},
		update: (data: object) => {
			return request({
				url: 'management/appattr/update',
				method: 'put',
				data,
			});
		},

		delete: (id: string) => {
			return request({
				url: `management/appattr/delete/${id}`,
				method: 'delete',
			});
		},

		view: (id: string) => {
			return request({
				url: `management/appattr/view/${id}`,
			});
		},

		used: (id: string) => {
			return request({
				url: `management/appattr/used/${id}`,
			});
		},

		search: (data: object) => {
			return request({
				url: 'management/appattr/search',
				method: 'post',
				data,
			});
		},
	};
}
